#ifndef _WINDOW_H_
# define _WINDOW_H_

# include <SDL/SDL.h>
# include <string>
# include <map>
# include "Utils\\IArgs.h"
# include "Utils\\AWindow.h"
# include "Utils\\ScreenManager.h"

class Window : public SDL::UTILS::AWindow
{
private:
	typedef void (Window::*ScreenExec)();
	SDL_Event m_event;
	bool m_quit;
	SDL::UTILS::ScreenManager m_screens;
	std::string m_currentScreen;
	std::map<std::string, ScreenExec> m_screenExecutors;

public:
	Window();
	virtual ~Window();

	virtual int Exec();
	void LoadScreen(std::string const& _name, SDL::UTILS::ScreenManager::MngrFunc,
					SDL::UTILS::IArgs* _datas = NULL, bool _delete = true);

private:
	void InitAll();
	void EditorScreenExec();
	void SimulatorScreenExec();
	void ManageEvents();
};


#endif // _WINDOW_H_
